import request from "@/request/ajax.js";
let ztpmTenant =
  import.meta.env.VITE_API_URL +
  import.meta.env.VITE_API_ALIAS +
  import.meta.env.VITE_API_TENANT;

// 部门列表
export const apiGetDepartList = (params, msg) => {
  return request.get(ztpmTenant + "/department/tree", params, msg);
};

// 新增部门
export const apiPostCreateDepartment = (data, msg) => {
  return request.post(ztpmTenant + "/department/create", data, msg);
};
// 修改部门
export const apiPutUpdateDepartment = ( data, msg) => {
    return request.put(ztpmTenant + "/department/update", data, msg);
};
// 删除部门
export const apiDeleteDepartment = (params, msg) => {
    return request.delete(ztpmTenant + "/department/delete", params, msg);
};